package rmioverlay.lib.users;

import java.util.HashMap;

public class UserList {
	
	public static final UserList LIST = new UserList();
	private HashMap<String, User> l;
	
	private UserList(){
		l = new HashMap<String, User>();
	}
	
	public static void setUserList(HashMap<String, User> pUserList){
		LIST.l = pUserList;
	}
	
	public static User getUser(String login){
		return LIST.l.get(login);
	
	}
	
	public static void addUser(User user){
		String login = user.getLogin();
		LIST.l.put(login, user);
		
	}
	
	public void delUser(String login){
		LIST.l.remove(login);
		
	}
	


}
